<?php
//$vars['helper']->insertMessage();
//$name = $vars['forum']->getName();
//$descr = $vars['forum']->getDescription();
//echo "name is [$name]";
//echo "descr is [$descr]";


$vars['helper']->insertMessage();
$forums = $vars['forums'];
if( $forums )
	foreach( $forums as $forum ) {
		?><div>
<p><?php
		echo $forum->getName();
		?><span><a href=" <?php
		$vars['helper']->insertHref( 'Forum', 'displayForm', array( 'forumId' => $forum->getId() ) );
		?>"
	title="edit">&nbsp;Edit</a><a
	href=" <?php
		$vars['helper']->insertHref( 'Forum', 'displaySingleForum', array( 'forumId' => $forum->getId() ) );
		?>" title="edit">&nbsp;View</a></span></p>
</div><?php
	}
else {
	echo '<div class="message info">Currently no forum</div>';
}?>
<a href="<?php echo $vars['helper']->createHref('Forum', 'displayForm')?>">Create new forum</a><br/>